package com.wd.center.controller;

import com.wd.center.pattern.singleton.Enumerate;

import java.util.concurrent.atomic.AtomicInteger;

public class TestAction {
    public static void main(String[] args) {
        Enumerate.INSTANCE.whateverMethod();
    }

    public static void testmultithreading() {
        AtomicInteger j = new AtomicInteger();
        Thread thread = new Thread((() -> {
            for (int i = 0; i < 6; i++) {
                j.set(i);
                System.out.println(j.get());
            }
        }));
        thread.start();
        System.out.println(thread.getName() + ">>" + j.get());
    }
}


